from Base import Base
from selenium.webdriver.common.by import By

class Page(Base):
    # iframe id="x-URS-iframe1758716957209.2825"
    kj_loc = (By.XPATH,'//iframe[starts-with(@id,x-URS-iframe175)]')
    def kj(self):
        self.iframe(self.kj_loc)
    # name="email"
    name_loc = (By.NAME,'email')
    def name(self):
        self.send_keys(self.name_loc,'s3080172040')
    # name="password"
    password_loc = (By.NAME,'password')
    def password(self):
        self.send_keys(self.password_loc,'Xff030303')
    # id="dologin"
    dologin_loc = (By.ID,'dologin')
    def dologin(self):
        self.click(self.dologin_loc)

    def luoji_01(self):
        self.open_url('https://mail.126.com/')
        self.kj()
        self.name()
        self.password()
        self.dologin()
        self.iframe_content()